<%@ include file="/taglibs.jsp"%>
<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<!-- header start -->
<head>
<title>北京邮电大学学生党员在线学习中心</title>
<link href="${ctx}/css/pagination.css" rel="stylesheet" type="text/css" />
</head>
<div id="nav_bar">
    <img id="nav_bar_left" src="../../../styles/nav_bar_left.png" alt=""/>
    <div id="welcome_label">欢迎您，&nbsp;<s:property value="#session.session_user.adminName" />!</div>
    <img id="nav_bar_seperator" src="../../../styles/nav_bar_seperator.png" alt=""/>
    <div id="nav_location">
        <img id="nav_bar_point" src="../../../styles/nav_bar_point.png" alt="" />
        <div id="nav_cur_location">当前位置：&nbsp;<a href="${ctx}/AdminNoticeAction_adminNotice">学习公告管理</a>&nbsp;&nbsp;>&nbsp;&nbsp;学习公告</div>
    </div>
    <img style="float:right; width:5px;" src="../../../styles/nav_bar_right.png" alt=""/>
    <a id="nav_logout" href="${ctx}/logoutAction_adminLogout">[安全退出]</a>
</div>
<div style="clear:both; height:5px;">&nbsp;</div>

<div style="min-height:450px;">
	<div id="side_menu" style="min-height:650px;">
	    <div id="side_menu_title">
	        <img src="../../../styles/side_menu_title_img.png" alt="" />
	        <span>学习公告管理</span>
	    </div>
	    <div id="side_menu_title_bottom">&nbsp;</div>
	    <div class="side_sub_menu_focus">
	        <div class="side_menu_point">&nbsp;</div>
	        <a href="${ctx}/AdminNoticeAction_adminNotice">学习公告</a>
	    </div>
	</div>
	
	<div id="main_content">
	    <div id="main_content_title">
	        <img src="../../../styles/content_title_img.png" alt="" />
	        <span>学习公告</span>
	    </div>
	    <div class="main_content_title_bottom">&nbsp;</div>

			<s:form action="AdminNoticeAction_adminNotice" method="post" theme="simple">
				<table>
					<tr> 
						<td>请输入查询内容：</td>
						<td><input type="text" name="queryTitle" value="<s:property value="queryTitle"/>" size=60></td>
						<td style="width:60px;text-align:center;">
								<input type="submit"  name="button" id="button" class="input-button"  value="查询"/>
						 </td>
						 <td>
								<input id="learnCenter" name="learnCenter" type="button" class="input-button" value="发布学习公告" onclick="window.location.href='${ctx}/AdminNoticeAction_toPostNotice?pageNow=<s:property value="pageNow"/>&queryNoticeTitle=<s:property value="queryNoticeTitle"/>'" />
						 </td>
					</tr>
				</table>
			</s:form>
		
       <br/>
       
		<table class="list-table" cellpadding="0" cellspacing="0">
			<tr bgcolor="#F1F4FB">
				<th align="center">标题</th>
				<th align="center">发布者</th>
				<th align="center">发布时间</th>
				<th align="center">操作</th>
			</tr>
			<s:iterator value="learnCenters" status="st">
				<tr>
					<td align="center">
					<a target="_blank" href="${ctx}/AdminNoticeAction_viewAdminNotice?id=<s:property value="id"/>" title="<s:property value="title"/>">
								 <s:if test="%{null!=title && title.length()>30}"> <s:property value="title.substring(0,29)+'...'"/></s:if>
                                 <s:else><s:property value="title"/></s:else>
								</a></td>
					<td align="center"><s:property value="posterName" /></td>
					<td align="center"><s:date name="posterTime" format="yyyy-MM-dd" /></td>
					<td align="center">
					    <a href="${ctx}/AdminNoticeAction_toUpdateNotice?id=<s:property value="id"/>&pageNow=<s:property value="pageNow"/>&queryTitle=<s:property value="queryTitle"/>">修改</a>
						<a onclick="return confirm('确定要删除该记录吗?')" href="${ctx}/AdminNoticeAction_deleteNotice?id=<s:property value="id"/>&pageNow=<s:property value="pageNow"/>&queryTitle=<s:property value="queryTitle"/>">删除</a>
					</td>
				</tr>
			</s:iterator>
		</table>
        <br/>
		<table width="97%" border="0" align="center" cellpadding="0"
			cellspacing="0" bgcolor="#F5F6F8">
			<tr>
				<td>
					<div align="center">
						<s:property value="paginationCode" escape="false" />
					</div>
				</td>
			</tr>
		</table> 
	</div>
	<div style="clear:both">&nbsp;</div>
</div>
